package com.lagou.task10;

public class Test {


    static {
        x = 5;
//        System.out.println("xx = " + x);//err：变量没有定义
    }
    static int x, y;
    public static void main(String args[]) {
        x--;
        myMethod();
        System.out.println(x + y + ++x);
    }

    public static void myMethod() {
        y = x++ + ++x;

    }

}
